#include "camerawindow.h"
#include "ui_camerawindow.h"
#include <opencv2/core.hpp>

using namespace cv;
using namespace std;

CameraWindow::CameraWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::CameraWindow)
{
    ui->setupUi(this);

    // 消除图像显示控件边框，清空文本
    ui->lab_CalImgs->setText("");
    ui->lab_CalImgs->setFrameShape(QFrame::NoFrame);
    ui->lab_CamView->setText("");
    // 获取相机列表

}

CameraWindow::~CameraWindow()
{
    delete ui;
}

void CameraWindow::openCamera(int camId) {
    VideoCapture cam(camId);
    if (!cam.isOpened()) {
        cout << "open failed" << endl;
        return;
    }
    Mat frame;

}
